package android.fin;

import org.xml.sax.Attributes;
import org.xml.sax.SAXException;
import org.xml.sax.helpers.DefaultHandler;


public class CiudadHandler extends DefaultHandler {

	private String horaTemperatura = null;

	public String getHoraTemperatura() {
		return this.horaTemperatura;
	}
	public void setHoraTemperatura(String h){
		this.horaTemperatura=h;
	}
	@Override
	public void startDocument() throws SAXException {
		
	}

	@Override
	public void endDocument() throws SAXException {
	}

	@Override
	public void startElement(String namespaceURI, String localName, String qName, Attributes atts) throws SAXException {

		String s=atts.getValue("<formatted_address>");
		
		if(localName.equals("temp_c")){
			this.horaTemperatura=s;
		}
	}
	

	@Override
	public void endElement(String namespaceURI, String localName, String qName) throws SAXException {
	}

	@Override
	public void characters(char ch[], int start, int length) {
	}
}

